package com.atguigu.gulimall.member.service;

import com.atguigu.common.to.SociaUser;
import com.atguigu.gulimall.member.excepiton.PhoneExistException;
import com.atguigu.gulimall.member.excepiton.UserNameExistException;
import com.atguigu.gulimall.member.vo.MemberRegisVo;
import com.atguigu.gulimall.member.vo.UserLoginVo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.member.entity.MemberEntity;

import java.util.Map;

/**
 * 会员
 *
 * @author wang
 * @email sunlightcs@gmail.com
 * @date 2020-12-10 10:56:38
 */
public interface MemberService extends IService<MemberEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void regist(MemberRegisVo vo);

    void checkUserNameUnique(String userName) throws UserNameExistException;
    void checkPhoneUnique(String phone) throws PhoneExistException;

    MemberEntity login(UserLoginVo vo);

    MemberEntity login(SociaUser sociaUser) throws Exception;
}

